package main

import (
	"github.com/spf13/pflag"
	"github.com/spf13/viper"
)

func main() {
	initViper()
	app := InitCommentServiceServer()
	err := app.Server.Serve()
	if err != nil {
		panic(err)
	}
}
func initViper() {
	cFile := pflag.String("config", "webook/comment/config/dev.yaml", "指定配置文件路径")
	pflag.Parse()
	viper.SetConfigFile(*cFile)

	if err := viper.ReadInConfig(); err != nil {
		panic(err)
	}
}
